from exceptions import Exception


class Warning(StandardError):
    '''
    Exception raised for important warnings like data
    truncations while inserting, etc. 
    '''

class Error(StandardError):
    '''
    Exception that is the base class of all other error
    exceptions. You can use this to catch all errors with one
    single 'except' statement
    '''

class InterfaceError(Error):
    '''
    Exception raised for errors that are related to the
    database interface rather than the database itself.
    '''

class DatabaseError(Error):
    pass

class DataError(DatabaseError):
    pass

class OperationalError(DatabaseError):
    pass

class IntegrityError(DatabaseError):
    pass

class InternalError(DatabaseError):
    pass

class ProgrammingError(DatabaseError):
    pass

class NotSupportedError(DatabaseError):
    pass

